% !TEX encoding = UTF-8 Unicode
% !TEX TS-program = XeLaTeX
% !BIB TS-program = biber
% !TEX useTabsWithFiles
% !TEX tabbedFile{TitlePage.tex}
% !TEX tabbedFile{Introduction.tex}
% !TEX tabbedFile{DeployingAndUsing.tex}
% !TEX tabbedFile{Building.tex}
% !TEX tabbedFile{Appendices.tex}

\documentclass[12pt,letterpaper,openany,oneside,draft]{book}

%\usepackage{xifthen}
%\newboolean{enablePortionMarkings}
%\setboolean{enablePortionMarkings}{true}

\usepackage{parskip}				% Begin paragraphs with empty line, not indent
\usepackage{xcolor}
\usepackage{titling}
\usepackage{fnpct}
\usepackage[inline]{enumitem}
\usepackage{acro}
\usepackage[final]{graphicx}
\usepackage{booktabs}
\usepackage{array}
\usepackage{ragged2e}
%\usepackage{colortbl}
%\usepackage{rotating}
%\usepackage{marginnote}
\usepackage{relsize}
\usepackage{fancyhdr}
%\usepackage{lastpage}
%\usepackage{lipsum}
\usepackage{amsmath}
\usepackage{amssymb}
%\usepackage[retainorgcmds]{IEEEtrantools}
%\usepackage{skmath}
%\usepackage{tikz}
\usepackage{path}
\usepackage{dirtree}
%\usepackage[firstpage]{draftwatermark}
%\usepackage{todonotes}
%\usepackage[T1]{fontenc}		% Enables curly braces in emails within \institute
\usepackage[style=numeric,backref,backend=biber]{biblatex}
\usepackage{fontspec,xltxtra,xunicode}
\usepackage{iffont}
\usepackage{unicode-math}
\usepackage[final]{hyperref}	% Should be the last use-package command

%\newcommand{\red}[1]{{\color{red}#1}}
%\newcommand{\paraleader}[1]{\textbf{#1}}
\newcommand{\urlcite}[1]{\footnote{\url{#1}}}
\newcommand{\headingrule}{\midrule[\heavyrulewidth]}
%\newcommand{\classmark}{\textbf{\emph{UNCLASSIFIED}}}
%\newcommand{\themestatement}[1]{\framebox{\parbox{0.97\columnwidth}{\emph{#1}}}}
\newcommand{\icm}[1]{}

\input{acronyms.tex}
\bibliography{references}

\title{\acl{pmnt} User Guide}
\author{Ian Emmons}
\date{\today}
%\setlength{\droptitle}{-50pt}
%\pretitle{\begin{center}\LARGE}
%\posttitle{\par\end{center}\vskip 0.5em}
%\preauthor{\begin{center}\large\lineskip 0.5em\begin{tabular}[t]{c}}
%\postauthor{\end{tabular}\par\end{center}}
%\predate{\begin{center}\large}
%\postdate{\par\end{center}}

\settofirstfound{\mainfont}{Georgia,TeX Gyre Bonum,Constantia}
\settofirstfound{\sansfont}{Verdana,TeX Gyre Heros,Gill Sans}
\settofirstfound{\monofont}{Consolas,Menlo,Andale Mono}
\settofirstfound{\mathfont}{Cambria Math,TeX Gyre Bonum Math,STIX Math}
\defaultfontfeatures{Mapping=tex-text}
\setmainfont{\mainfont}
\setsansfont{\sansfont}[Scale=MatchLowercase]
\setmonofont{\monofont}[Scale=MatchLowercase,PunctuationSpace=WordSpace,Mapping=]
\setmathfont{\mathfont}
%\setmainfont{Georgia}
%\setmainfont{TeX Gyre Pagella}[Numbers=Uppercase]
%\setmainfont{Constantia}[Numbers=Uppercase]
%\setsansfont{Verdana}[Scale=MatchLowercase]
%\setsansfont{TeX Gyre Heros}[Scale=MatchLowercase]
%\setmonofont{Consolas}[Scale=MatchLowercase,PunctuationSpace=WordSpace,Mapping=]
%\setmonofont{Menlo}[Scale=MatchLowercase,PunctuationSpace=WordSpace,Mapping=]
%\setmathfont{TeX Gyre Pagella Math}
%\setmathfont{STIX Math}
%\setmathfont{Cambria Math}

\pagestyle{fancy}
\renewcommand{\chaptermark}[1]
	{\markboth{\chaptername \ \thechapter.\ #1}{}}
\fancyhead[L]{\textsl{\leftmark}}
\fancyhead[R]{}
\setlength{\headheight}{15pt}

%\urlstyle{rm}
\definecolor{hyperlinkcolor}{rgb}{0,0,0.625}
\hypersetup{
	final=true,
	unicode=true,
	bookmarksnumbered=true,
	pdftitle={Parliament User Guide},
	pdfauthor={\theauthor},
	colorlinks=true,
	allcolors=hyperlinkcolor
}

%\SetWatermarkAngle{45}
%\SetWatermarkLightness{0.8}		% 1 = white, 0 = black
%\SetWatermarkFontSize{5cm}
%\SetWatermarkScale{1.2}
%\SetWatermarkText{\textsc{Draft}}

\hyphenation{Arc-GIS Arc-Map}
\hyphenation{co-ref-er-ence co-ref-er-enc-es}
\hyphenation{da-ta-base da-ta-bas-es}
\hyphenation{geo-spa-tial}
\hyphenation{ra-pid-ly}
\hyphenation{ray-the-on}
\hyphenation{serv-let serv-lets}
\hyphenation{trac-ta-ble}
\hyphenation{war-fight-er war-fight-ers}

\begin{document}
\acuse{pmnt} % Only long & short forms, never "first appearance"
\acuse{url} % This one is too common to bother spelling it out

\frontmatter
\input{TitlePage.tex}
\mainmatter

\input{Introduction.tex}
\input{DeployingAndUsing.tex}
\input{Building.tex}

\appendix

\input{Appendices.tex}

\backmatter

\acsetup{
	list-name=Glossary,
	list-heading=chapter,
	extra-style=plain,
	page-style=paren}
\printacronyms

\sloppy
\printbibliography[heading=bibnumbered]

\end{document}
